const router = require('koa-router')();
const guide = require('../modules/guide');

//获取数据
router.get('/examguide',async(ctx,next) => {
    ctx.body = await guide.getexamGuide();
})
//增加数据
router.post('/examguide',async(ctx,next) => {
    ctx.body = await guide.addexamGuide(ctx.request.body);
})
//删除数据
router.delete('/examguide/:guide_id',async(ctx,next) => {
    ctx.body = await guide.deleteexamGuide(ctx.params);
})
//修改数据
router.put('/examguide',async(ctx,next)=>{
    ctx.body = await guide.putexamGuide(ctx.request.body);
})

module.exports = router;
